// Copyright 2024 Google LLC All Rights Reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//     http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

// This code was autogenerated. Do not edit directly.
// Generated by the protocol buffer compiler.  DO NOT EDIT!
// NO CHECKED-IN PROTOBUF GENCODE
// source: google/api/http.proto
// Protobuf C++ Version: 6.31.1

#include "google/api/http.pb.h"

#include <algorithm>
#include <type_traits>
#include "google/protobuf/io/coded_stream.h"
#include "google/protobuf/generated_message_tctable_impl.h"
#include "google/protobuf/extension_set.h"
#include "google/protobuf/generated_message_util.h"
#include "google/protobuf/wire_format_lite.h"
#include "google/protobuf/descriptor.h"
#include "google/protobuf/generated_message_reflection.h"
#include "google/protobuf/reflection_ops.h"
#include "google/protobuf/wire_format.h"
// @@protoc_insertion_point(includes)

// Must be included last.
#include "google/protobuf/port_def.inc"
PROTOBUF_PRAGMA_INIT_SEG
namespace _pb = ::google::protobuf;
namespace _pbi = ::google::protobuf::internal;
namespace _fl = ::google::protobuf::internal::field_layout;
namespace google {
namespace api {

inline constexpr CustomHttpPattern::Impl_::Impl_(
    ::_pbi::ConstantInitialized) noexcept
      : _cached_size_{0},
        kind_(
            &::google::protobuf::internal::fixed_address_empty_string,
            ::_pbi::ConstantInitialized()),
        path_(
            &::google::protobuf::internal::fixed_address_empty_string,
            ::_pbi::ConstantInitialized()) {}

template <typename>
PROTOBUF_CONSTEXPR CustomHttpPattern::CustomHttpPattern(::_pbi::ConstantInitialized)
#if defined(PROTOBUF_CUSTOM_VTABLE)
    : ::google::protobuf::Message(CustomHttpPattern_class_data_.base()),
#else   // PROTOBUF_CUSTOM_VTABLE
    : ::google::protobuf::Message(),
#endif  // PROTOBUF_CUSTOM_VTABLE
      _impl_(::_pbi::ConstantInitialized()) {
}
struct CustomHttpPatternDefaultTypeInternal {
  PROTOBUF_CONSTEXPR CustomHttpPatternDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {}
  ~CustomHttpPatternDefaultTypeInternal() {}
  union {
    CustomHttpPattern _instance;
  };
};

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT AGONES_EXPORT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 CustomHttpPatternDefaultTypeInternal _CustomHttpPattern_default_instance_;

inline constexpr HttpRule::Impl_::Impl_(
    ::_pbi::ConstantInitialized) noexcept
      : _cached_size_{0},
        additional_bindings_{},
        selector_(
            &::google::protobuf::internal::fixed_address_empty_string,
            ::_pbi::ConstantInitialized()),
        body_(
            &::google::protobuf::internal::fixed_address_empty_string,
            ::_pbi::ConstantInitialized()),
        response_body_(
            &::google::protobuf::internal::fixed_address_empty_string,
            ::_pbi::ConstantInitialized()),
        pattern_{},
        _oneof_case_{} {}

template <typename>
PROTOBUF_CONSTEXPR HttpRule::HttpRule(::_pbi::ConstantInitialized)
#if defined(PROTOBUF_CUSTOM_VTABLE)
    : ::google::protobuf::Message(HttpRule_class_data_.base()),
#else   // PROTOBUF_CUSTOM_VTABLE
    : ::google::protobuf::Message(),
#endif  // PROTOBUF_CUSTOM_VTABLE
      _impl_(::_pbi::ConstantInitialized()) {
}
struct HttpRuleDefaultTypeInternal {
  PROTOBUF_CONSTEXPR HttpRuleDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {}
  ~HttpRuleDefaultTypeInternal() {}
  union {
    HttpRule _instance;
  };
};

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT AGONES_EXPORT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 HttpRuleDefaultTypeInternal _HttpRule_default_instance_;

inline constexpr Http::Impl_::Impl_(
    ::_pbi::ConstantInitialized) noexcept
      : _cached_size_{0},
        rules_{},
        fully_decode_reserved_expansion_{false} {}

template <typename>
PROTOBUF_CONSTEXPR Http::Http(::_pbi::ConstantInitialized)
#if defined(PROTOBUF_CUSTOM_VTABLE)
    : ::google::protobuf::Message(Http_class_data_.base()),
#else   // PROTOBUF_CUSTOM_VTABLE
    : ::google::protobuf::Message(),
#endif  // PROTOBUF_CUSTOM_VTABLE
      _impl_(::_pbi::ConstantInitialized()) {
}
struct HttpDefaultTypeInternal {
  PROTOBUF_CONSTEXPR HttpDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {}
  ~HttpDefaultTypeInternal() {}
  union {
    Http _instance;
  };
};

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT AGONES_EXPORT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 HttpDefaultTypeInternal _Http_default_instance_;
}  // namespace api
}  // namespace google
static constexpr const ::_pb::EnumDescriptor *PROTOBUF_NONNULL *PROTOBUF_NULLABLE
    file_level_enum_descriptors_google_2fapi_2fhttp_2eproto = nullptr;
static constexpr const ::_pb::ServiceDescriptor *PROTOBUF_NONNULL *PROTOBUF_NULLABLE
    file_level_service_descriptors_google_2fapi_2fhttp_2eproto = nullptr;
const ::uint32_t
    TableStruct_google_2fapi_2fhttp_2eproto::offsets[] ABSL_ATTRIBUTE_SECTION_VARIABLE(
        protodesc_cold) = {
        0x081, // bitmap
        PROTOBUF_FIELD_OFFSET(::google::api::Http, _impl_._has_bits_),
        5, // hasbit index offset
        PROTOBUF_FIELD_OFFSET(::google::api::Http, _impl_.rules_),
        PROTOBUF_FIELD_OFFSET(::google::api::Http, _impl_.fully_decode_reserved_expansion_),
        ~0u,
        0,
        0x085, // bitmap
        PROTOBUF_FIELD_OFFSET(::google::api::HttpRule, _impl_._has_bits_),
        PROTOBUF_FIELD_OFFSET(::google::api::HttpRule, _impl_._oneof_case_[0]),
        15, // hasbit index offset
        PROTOBUF_FIELD_OFFSET(::google::api::HttpRule, _impl_.selector_),
        ::_pbi::kInvalidFieldOffsetTag,
        ::_pbi::kInvalidFieldOffsetTag,
        ::_pbi::kInvalidFieldOffsetTag,
        ::_pbi::kInvalidFieldOffsetTag,
        ::_pbi::kInvalidFieldOffsetTag,
        ::_pbi::kInvalidFieldOffsetTag,
        PROTOBUF_FIELD_OFFSET(::google::api::HttpRule, _impl_.body_),
        PROTOBUF_FIELD_OFFSET(::google::api::HttpRule, _impl_.response_body_),
        PROTOBUF_FIELD_OFFSET(::google::api::HttpRule, _impl_.additional_bindings_),
        PROTOBUF_FIELD_OFFSET(::google::api::HttpRule, _impl_.pattern_),
        0,
        ~0u,
        ~0u,
        ~0u,
        ~0u,
        ~0u,
        ~0u,
        1,
        2,
        ~0u,
        0x081, // bitmap
        PROTOBUF_FIELD_OFFSET(::google::api::CustomHttpPattern, _impl_._has_bits_),
        5, // hasbit index offset
        PROTOBUF_FIELD_OFFSET(::google::api::CustomHttpPattern, _impl_.kind_),
        PROTOBUF_FIELD_OFFSET(::google::api::CustomHttpPattern, _impl_.path_),
        0,
        1,
};

static const ::_pbi::MigrationSchema
    schemas[] ABSL_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
        {0, sizeof(::google::api::Http)},
        {7, sizeof(::google::api::HttpRule)},
        {32, sizeof(::google::api::CustomHttpPattern)},
};
static const ::_pb::Message* PROTOBUF_NONNULL const file_default_instances[] = {
    &::google::api::_Http_default_instance_._instance,
    &::google::api::_HttpRule_default_instance_._instance,
    &::google::api::_CustomHttpPattern_default_instance_._instance,
};
const char descriptor_table_protodef_google_2fapi_2fhttp_2eproto[] ABSL_ATTRIBUTE_SECTION_VARIABLE(
    protodesc_cold) = {
    "\n\025google/api/http.proto\022\ngoogle.api\"T\n\004H"
    "ttp\022#\n\005rules\030\001 \003(\0132\024.google.api.HttpRule"
    "\022\'\n\037fully_decode_reserved_expansion\030\002 \001("
    "\010\"\201\002\n\010HttpRule\022\020\n\010selector\030\001 \001(\t\022\r\n\003get\030"
    "\002 \001(\tH\000\022\r\n\003put\030\003 \001(\tH\000\022\016\n\004post\030\004 \001(\tH\000\022\020"
    "\n\006delete\030\005 \001(\tH\000\022\017\n\005patch\030\006 \001(\tH\000\022/\n\006cus"
    "tom\030\010 \001(\0132\035.google.api.CustomHttpPattern"
    "H\000\022\014\n\004body\030\007 \001(\t\022\025\n\rresponse_body\030\014 \001(\t\022"
    "1\n\023additional_bindings\030\013 \003(\0132\024.google.ap"
    "i.HttpRuleB\t\n\007pattern\"/\n\021CustomHttpPatte"
    "rn\022\014\n\004kind\030\001 \001(\t\022\014\n\004path\030\002 \001(\tBj\n\016com.go"
    "ogle.apiB\tHttpProtoP\001ZAgoogle.golang.org"
    "/genproto/googleapis/api/annotations;ann"
    "otations\370\001\001\242\002\004GAPIb\006proto3"
};
static ::absl::once_flag descriptor_table_google_2fapi_2fhttp_2eproto_once;
PROTOBUF_CONSTINIT const ::_pbi::DescriptorTable descriptor_table_google_2fapi_2fhttp_2eproto = {
    false,
    false,
    546,
    descriptor_table_protodef_google_2fapi_2fhttp_2eproto,
    "google/api/http.proto",
    &descriptor_table_google_2fapi_2fhttp_2eproto_once,
    nullptr,
    0,
    3,
    schemas,
    file_default_instances,
    TableStruct_google_2fapi_2fhttp_2eproto::offsets,
    file_level_enum_descriptors_google_2fapi_2fhttp_2eproto,
    file_level_service_descriptors_google_2fapi_2fhttp_2eproto,
};
namespace google {
namespace api {
// ===================================================================

class Http::_Internal {
 public:
  using HasBits =
      decltype(::std::declval<Http>()._impl_._has_bits_);
  static constexpr ::int32_t kHasBitsOffset =
      8 * PROTOBUF_FIELD_OFFSET(Http, _impl_._has_bits_);
};

Http::Http(::google::protobuf::Arena* PROTOBUF_NULLABLE arena)
#if defined(PROTOBUF_CUSTOM_VTABLE)
    : ::google::protobuf::Message(arena, Http_class_data_.base()) {
#else   // PROTOBUF_CUSTOM_VTABLE
    : ::google::protobuf::Message(arena) {
#endif  // PROTOBUF_CUSTOM_VTABLE
  SharedCtor(arena);
  // @@protoc_insertion_point(arena_constructor:google.api.Http)
}
PROTOBUF_NDEBUG_INLINE Http::Impl_::Impl_(
    ::google::protobuf::internal::InternalVisibility visibility,
    ::google::protobuf::Arena* PROTOBUF_NULLABLE arena, const Impl_& from,
    const ::google::api::Http& from_msg)
      : _has_bits_{from._has_bits_},
        _cached_size_{0},
        rules_{visibility, arena, from.rules_} {}

Http::Http(
    ::google::protobuf::Arena* PROTOBUF_NULLABLE arena,
    const Http& from)
#if defined(PROTOBUF_CUSTOM_VTABLE)
    : ::google::protobuf::Message(arena, Http_class_data_.base()) {
#else   // PROTOBUF_CUSTOM_VTABLE
    : ::google::protobuf::Message(arena) {
#endif  // PROTOBUF_CUSTOM_VTABLE
  Http* const _this = this;
  (void)_this;
  _internal_metadata_.MergeFrom<::google::protobuf::UnknownFieldSet>(
      from._internal_metadata_);
  new (&_impl_) Impl_(internal_visibility(), arena, from._impl_, from);
  _impl_.fully_decode_reserved_expansion_ = from._impl_.fully_decode_reserved_expansion_;

  // @@protoc_insertion_point(copy_constructor:google.api.Http)
}
PROTOBUF_NDEBUG_INLINE Http::Impl_::Impl_(
    ::google::protobuf::internal::InternalVisibility visibility,
    ::google::protobuf::Arena* PROTOBUF_NULLABLE arena)
      : _cached_size_{0},
        rules_{visibility, arena} {}

inline void Http::SharedCtor(::_pb::Arena* PROTOBUF_NULLABLE arena) {
  new (&_impl_) Impl_(internal_visibility(), arena);
  _impl_.fully_decode_reserved_expansion_ = {};
}
Http::~Http() {
  // @@protoc_insertion_point(destructor:google.api.Http)
  SharedDtor(*this);
}
inline void Http::SharedDtor(MessageLite& self) {
  Http& this_ = static_cast<Http&>(self);
  this_._internal_metadata_.Delete<::google::protobuf::UnknownFieldSet>();
  ABSL_DCHECK(this_.GetArena() == nullptr);
  this_._impl_.~Impl_();
}

inline void* PROTOBUF_NONNULL Http::PlacementNew_(
    const void* PROTOBUF_NONNULL, void* PROTOBUF_NONNULL mem,
    ::google::protobuf::Arena* PROTOBUF_NULLABLE arena) {
  return ::new (mem) Http(arena);
}
constexpr auto Http::InternalNewImpl_() {
  constexpr auto arena_bits = ::google::protobuf::internal::EncodePlacementArenaOffsets({
      PROTOBUF_FIELD_OFFSET(Http, _impl_.rules_) +
          decltype(Http::_impl_.rules_)::
              InternalGetArenaOffset(
                  ::google::protobuf::Message::internal_visibility()),
  });
  if (arena_bits.has_value()) {
    return ::google::protobuf::internal::MessageCreator::ZeroInit(
        sizeof(Http), alignof(Http), *arena_bits);
  } else {
    return ::google::protobuf::internal::MessageCreator(&Http::PlacementNew_,
                                 sizeof(Http),
                                 alignof(Http));
  }
}
constexpr auto Http::InternalGenerateClassData_() {
  return ::google::protobuf::internal::ClassDataFull{
      ::google::protobuf::internal::ClassData{
          &_Http_default_instance_._instance,
          &_table_.header,
          nullptr,  // OnDemandRegisterArenaDtor
          nullptr,  // IsInitialized
          &Http::MergeImpl,
          ::google::protobuf::Message::GetNewImpl<Http>(),
#if defined(PROTOBUF_CUSTOM_VTABLE)
          &Http::SharedDtor,
          ::google::protobuf::Message::GetClearImpl<Http>(), &Http::ByteSizeLong,
              &Http::_InternalSerialize,
#endif  // PROTOBUF_CUSTOM_VTABLE
          PROTOBUF_FIELD_OFFSET(Http, _impl_._cached_size_),
          false,
      },
      &Http::kDescriptorMethods,
      &descriptor_table_google_2fapi_2fhttp_2eproto,
      nullptr,  // tracker
  };
}

PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 const
    ::google::protobuf::internal::ClassDataFull Http_class_data_ =
        Http::InternalGenerateClassData_();

PROTOBUF_ATTRIBUTE_WEAK const ::google::protobuf::internal::ClassData* PROTOBUF_NONNULL
Http::GetClassData() const {
  ::google::protobuf::internal::PrefetchToLocalCache(&Http_class_data_);
  ::google::protobuf::internal::PrefetchToLocalCache(Http_class_data_.tc_table);
  return Http_class_data_.base();
}
PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1
const ::_pbi::TcParseTable<1, 2, 1, 0, 2>
Http::_table_ = {
  {
    PROTOBUF_FIELD_OFFSET(Http, _impl_._has_bits_),
    0, // no _extensions_
    2, 8,  // max_field_number, fast_idx_mask
    offsetof(decltype(_table_), field_lookup_table),
    4294967292,  // skipmap
    offsetof(decltype(_table_), field_entries),
    2,  // num_field_entries
    1,  // num_aux_entries
    offsetof(decltype(_table_), aux_entries),
    Http_class_data_.base(),
    nullptr,  // post_loop_handler
    ::_pbi::TcParser::GenericFallback,  // fallback
    #ifdef PROTOBUF_PREFETCH_PARSE_TABLE
    ::_pbi::TcParser::GetTable<::google::api::Http>(),  // to_prefetch
    #endif  // PROTOBUF_PREFETCH_PARSE_TABLE
  }, {{
    // bool fully_decode_reserved_expansion = 2;
    {::_pbi::TcParser::SingularVarintNoZag1<bool, offsetof(Http, _impl_.fully_decode_reserved_expansion_), 0>(),
     {16, 0, 0, PROTOBUF_FIELD_OFFSET(Http, _impl_.fully_decode_reserved_expansion_)}},
    // repeated .google.api.HttpRule rules = 1;
    {::_pbi::TcParser::FastMtR1,
     {10, 63, 0, PROTOBUF_FIELD_OFFSET(Http, _impl_.rules_)}},
  }}, {{
    65535, 65535
  }}, {{
    // repeated .google.api.HttpRule rules = 1;
    {PROTOBUF_FIELD_OFFSET(Http, _impl_.rules_), -1, 0,
    (0 | ::_fl::kFcRepeated | ::_fl::kMessage | ::_fl::kTvTable)},
    // bool fully_decode_reserved_expansion = 2;
    {PROTOBUF_FIELD_OFFSET(Http, _impl_.fully_decode_reserved_expansion_), _Internal::kHasBitsOffset + 0, 0,
    (0 | ::_fl::kFcOptional | ::_fl::kBool)},
  }},
  {{
      {::_pbi::TcParser::GetTable<::google::api::HttpRule>()},
  }},
  {{
  }},
};
PROTOBUF_NOINLINE void Http::Clear() {
// @@protoc_insertion_point(message_clear_start:google.api.Http)
  ::google::protobuf::internal::TSanWrite(&_impl_);
  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  _impl_.rules_.Clear();
  _impl_.fully_decode_reserved_expansion_ = false;
  _impl_._has_bits_.Clear();
  _internal_metadata_.Clear<::google::protobuf::UnknownFieldSet>();
}

#if defined(PROTOBUF_CUSTOM_VTABLE)
::uint8_t* PROTOBUF_NONNULL Http::_InternalSerialize(
    const ::google::protobuf::MessageLite& base, ::uint8_t* PROTOBUF_NONNULL target,
    ::google::protobuf::io::EpsCopyOutputStream* PROTOBUF_NONNULL stream) {
  const Http& this_ = static_cast<const Http&>(base);
#else   // PROTOBUF_CUSTOM_VTABLE
::uint8_t* PROTOBUF_NONNULL Http::_InternalSerialize(
    ::uint8_t* PROTOBUF_NONNULL target,
    ::google::protobuf::io::EpsCopyOutputStream* PROTOBUF_NONNULL stream) const {
  const Http& this_ = *this;
#endif  // PROTOBUF_CUSTOM_VTABLE
  // @@protoc_insertion_point(serialize_to_array_start:google.api.Http)
  ::uint32_t cached_has_bits = 0;
  (void)cached_has_bits;

  // repeated .google.api.HttpRule rules = 1;
  for (unsigned i = 0, n = static_cast<unsigned>(
                           this_._internal_rules_size());
       i < n; i++) {
    const auto& repfield = this_._internal_rules().Get(i);
    target =
        ::google::protobuf::internal::WireFormatLite::InternalWriteMessage(
            1, repfield, repfield.GetCachedSize(),
            target, stream);
  }

  // bool fully_decode_reserved_expansion = 2;
  if ((this_._impl_._has_bits_[0] & 0x00000001u) != 0) {
    if (this_._internal_fully_decode_reserved_expansion() != 0) {
      target = stream->EnsureSpace(target);
      target = ::_pbi::WireFormatLite::WriteBoolToArray(
          2, this_._internal_fully_decode_reserved_expansion(), target);
    }
  }

  if (ABSL_PREDICT_FALSE(this_._internal_metadata_.have_unknown_fields())) {
    target =
        ::_pbi::WireFormat::InternalSerializeUnknownFieldsToArray(
            this_._internal_metadata_.unknown_fields<::google::protobuf::UnknownFieldSet>(::google::protobuf::UnknownFieldSet::default_instance), target, stream);
  }
  // @@protoc_insertion_point(serialize_to_array_end:google.api.Http)
  return target;
}

#if defined(PROTOBUF_CUSTOM_VTABLE)
::size_t Http::ByteSizeLong(const MessageLite& base) {
  const Http& this_ = static_cast<const Http&>(base);
#else   // PROTOBUF_CUSTOM_VTABLE
::size_t Http::ByteSizeLong() const {
  const Http& this_ = *this;
#endif  // PROTOBUF_CUSTOM_VTABLE
  // @@protoc_insertion_point(message_byte_size_start:google.api.Http)
  ::size_t total_size = 0;

  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void)cached_has_bits;

  ::_pbi::Prefetch5LinesFrom7Lines(&this_);
   {
    // repeated .google.api.HttpRule rules = 1;
    {
      total_size += 1UL * this_._internal_rules_size();
      for (const auto& msg : this_._internal_rules()) {
        total_size += ::google::protobuf::internal::WireFormatLite::MessageSize(msg);
      }
    }
  }
   {
    // bool fully_decode_reserved_expansion = 2;
    cached_has_bits = this_._impl_._has_bits_[0];
    if ((cached_has_bits & 0x00000001u) != 0) {
      if (this_._internal_fully_decode_reserved_expansion() != 0) {
        total_size += 2;
      }
    }
  }
  return this_.MaybeComputeUnknownFieldsSize(total_size,
                                             &this_._impl_._cached_size_);
}

void Http::MergeImpl(::google::protobuf::MessageLite& to_msg, const ::google::protobuf::MessageLite& from_msg) {
  auto* const _this = static_cast<Http*>(&to_msg);
  auto& from = static_cast<const Http&>(from_msg);
  // @@protoc_insertion_point(class_specific_merge_from_start:google.api.Http)
  ABSL_DCHECK_NE(&from, _this);
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  _this->_internal_mutable_rules()->MergeFrom(
      from._internal_rules());
  cached_has_bits = from._impl_._has_bits_[0];
  if ((cached_has_bits & 0x00000001u) != 0) {
    if (from._internal_fully_decode_reserved_expansion() != 0) {
      _this->_impl_.fully_decode_reserved_expansion_ = from._impl_.fully_decode_reserved_expansion_;
    }
  }
  _this->_impl_._has_bits_[0] |= cached_has_bits;
  _this->_internal_metadata_.MergeFrom<::google::protobuf::UnknownFieldSet>(from._internal_metadata_);
}

void Http::CopyFrom(const Http& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:google.api.Http)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}


void Http::InternalSwap(Http* PROTOBUF_RESTRICT PROTOBUF_NONNULL other) {
  using ::std::swap;
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
  _impl_.rules_.InternalSwap(&other->_impl_.rules_);
  swap(_impl_.fully_decode_reserved_expansion_, other->_impl_.fully_decode_reserved_expansion_);
}

::google::protobuf::Metadata Http::GetMetadata() const {
  return ::google::protobuf::Message::GetMetadataImpl(GetClassData()->full());
}
// ===================================================================

class HttpRule::_Internal {
 public:
  using HasBits =
      decltype(::std::declval<HttpRule>()._impl_._has_bits_);
  static constexpr ::int32_t kHasBitsOffset =
      8 * PROTOBUF_FIELD_OFFSET(HttpRule, _impl_._has_bits_);
  static constexpr ::int32_t kOneofCaseOffset =
      PROTOBUF_FIELD_OFFSET(::google::api::HttpRule, _impl_._oneof_case_);
};

void HttpRule::set_allocated_custom(::google::api::CustomHttpPattern* PROTOBUF_NULLABLE custom) {
  ::google::protobuf::Arena* message_arena = GetArena();
  clear_pattern();
  if (custom) {
    ::google::protobuf::Arena* submessage_arena = custom->GetArena();
    if (message_arena != submessage_arena) {
      custom = ::google::protobuf::internal::GetOwnedMessage(message_arena, custom, submessage_arena);
    }
    set_has_custom();
    _impl_.pattern_.custom_ = custom;
  }
  // @@protoc_insertion_point(field_set_allocated:google.api.HttpRule.custom)
}
HttpRule::HttpRule(::google::protobuf::Arena* PROTOBUF_NULLABLE arena)
#if defined(PROTOBUF_CUSTOM_VTABLE)
    : ::google::protobuf::Message(arena, HttpRule_class_data_.base()) {
#else   // PROTOBUF_CUSTOM_VTABLE
    : ::google::protobuf::Message(arena) {
#endif  // PROTOBUF_CUSTOM_VTABLE
  SharedCtor(arena);
  // @@protoc_insertion_point(arena_constructor:google.api.HttpRule)
}
PROTOBUF_NDEBUG_INLINE HttpRule::Impl_::Impl_(
    ::google::protobuf::internal::InternalVisibility visibility,
    ::google::protobuf::Arena* PROTOBUF_NULLABLE arena, const Impl_& from,
    const ::google::api::HttpRule& from_msg)
      : _has_bits_{from._has_bits_},
        _cached_size_{0},
        additional_bindings_{visibility, arena, from.additional_bindings_},
        selector_(arena, from.selector_),
        body_(arena, from.body_),
        response_body_(arena, from.response_body_),
        pattern_{},
        _oneof_case_{from._oneof_case_[0]} {}

HttpRule::HttpRule(
    ::google::protobuf::Arena* PROTOBUF_NULLABLE arena,
    const HttpRule& from)
#if defined(PROTOBUF_CUSTOM_VTABLE)
    : ::google::protobuf::Message(arena, HttpRule_class_data_.base()) {
#else   // PROTOBUF_CUSTOM_VTABLE
    : ::google::protobuf::Message(arena) {
#endif  // PROTOBUF_CUSTOM_VTABLE
  HttpRule* const _this = this;
  (void)_this;
  _internal_metadata_.MergeFrom<::google::protobuf::UnknownFieldSet>(
      from._internal_metadata_);
  new (&_impl_) Impl_(internal_visibility(), arena, from._impl_, from);
  switch (pattern_case()) {
    case PATTERN_NOT_SET:
      break;
      case kGet:
        new (&_impl_.pattern_.get_) decltype(_impl_.pattern_.get_){arena, from._impl_.pattern_.get_};
        break;
      case kPut:
        new (&_impl_.pattern_.put_) decltype(_impl_.pattern_.put_){arena, from._impl_.pattern_.put_};
        break;
      case kPost:
        new (&_impl_.pattern_.post_) decltype(_impl_.pattern_.post_){arena, from._impl_.pattern_.post_};
        break;
      case kDelete:
        new (&_impl_.pattern_.delete__) decltype(_impl_.pattern_.delete__){arena, from._impl_.pattern_.delete__};
        break;
      case kPatch:
        new (&_impl_.pattern_.patch_) decltype(_impl_.pattern_.patch_){arena, from._impl_.pattern_.patch_};
        break;
      case kCustom:
        _impl_.pattern_.custom_ = ::google::protobuf::Message::CopyConstruct(arena, *from._impl_.pattern_.custom_);
        break;
  }

  // @@protoc_insertion_point(copy_constructor:google.api.HttpRule)
}
PROTOBUF_NDEBUG_INLINE HttpRule::Impl_::Impl_(
    ::google::protobuf::internal::InternalVisibility visibility,
    ::google::protobuf::Arena* PROTOBUF_NULLABLE arena)
      : _cached_size_{0},
        additional_bindings_{visibility, arena},
        selector_(arena),
        body_(arena),
        response_body_(arena),
        pattern_{},
        _oneof_case_{} {}

inline void HttpRule::SharedCtor(::_pb::Arena* PROTOBUF_NULLABLE arena) {
  new (&_impl_) Impl_(internal_visibility(), arena);
}
HttpRule::~HttpRule() {
  // @@protoc_insertion_point(destructor:google.api.HttpRule)
  SharedDtor(*this);
}
inline void HttpRule::SharedDtor(MessageLite& self) {
  HttpRule& this_ = static_cast<HttpRule&>(self);
  this_._internal_metadata_.Delete<::google::protobuf::UnknownFieldSet>();
  ABSL_DCHECK(this_.GetArena() == nullptr);
  this_._impl_.selector_.Destroy();
  this_._impl_.body_.Destroy();
  this_._impl_.response_body_.Destroy();
  if (this_.has_pattern()) {
    this_.clear_pattern();
  }
  this_._impl_.~Impl_();
}

void HttpRule::clear_pattern() {
// @@protoc_insertion_point(one_of_clear_start:google.api.HttpRule)
  ::google::protobuf::internal::TSanWrite(&_impl_);
  switch (pattern_case()) {
    case kGet: {
      _impl_.pattern_.get_.Destroy();
      break;
    }
    case kPut: {
      _impl_.pattern_.put_.Destroy();
      break;
    }
    case kPost: {
      _impl_.pattern_.post_.Destroy();
      break;
    }
    case kDelete: {
      _impl_.pattern_.delete__.Destroy();
      break;
    }
    case kPatch: {
      _impl_.pattern_.patch_.Destroy();
      break;
    }
    case kCustom: {
      if (GetArena() == nullptr) {
        delete _impl_.pattern_.custom_;
      } else if (::google::protobuf::internal::DebugHardenClearOneofMessageOnArena()) {
        ::google::protobuf::internal::MaybePoisonAfterClear(_impl_.pattern_.custom_);
      }
      break;
    }
    case PATTERN_NOT_SET: {
      break;
    }
  }
  _impl_._oneof_case_[0] = PATTERN_NOT_SET;
}


inline void* PROTOBUF_NONNULL HttpRule::PlacementNew_(
    const void* PROTOBUF_NONNULL, void* PROTOBUF_NONNULL mem,
    ::google::protobuf::Arena* PROTOBUF_NULLABLE arena) {
  return ::new (mem) HttpRule(arena);
}
constexpr auto HttpRule::InternalNewImpl_() {
  constexpr auto arena_bits = ::google::protobuf::internal::EncodePlacementArenaOffsets({
      PROTOBUF_FIELD_OFFSET(HttpRule, _impl_.additional_bindings_) +
          decltype(HttpRule::_impl_.additional_bindings_)::
              InternalGetArenaOffset(
                  ::google::protobuf::Message::internal_visibility()),
  });
  if (arena_bits.has_value()) {
    return ::google::protobuf::internal::MessageCreator::CopyInit(
        sizeof(HttpRule), alignof(HttpRule), *arena_bits);
  } else {
    return ::google::protobuf::internal::MessageCreator(&HttpRule::PlacementNew_,
                                 sizeof(HttpRule),
                                 alignof(HttpRule));
  }
}
constexpr auto HttpRule::InternalGenerateClassData_() {
  return ::google::protobuf::internal::ClassDataFull{
      ::google::protobuf::internal::ClassData{
          &_HttpRule_default_instance_._instance,
          &_table_.header,
          nullptr,  // OnDemandRegisterArenaDtor
          nullptr,  // IsInitialized
          &HttpRule::MergeImpl,
          ::google::protobuf::Message::GetNewImpl<HttpRule>(),
#if defined(PROTOBUF_CUSTOM_VTABLE)
          &HttpRule::SharedDtor,
          ::google::protobuf::Message::GetClearImpl<HttpRule>(), &HttpRule::ByteSizeLong,
              &HttpRule::_InternalSerialize,
#endif  // PROTOBUF_CUSTOM_VTABLE
          PROTOBUF_FIELD_OFFSET(HttpRule, _impl_._cached_size_),
          false,
      },
      &HttpRule::kDescriptorMethods,
      &descriptor_table_google_2fapi_2fhttp_2eproto,
      nullptr,  // tracker
  };
}

PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 const
    ::google::protobuf::internal::ClassDataFull HttpRule_class_data_ =
        HttpRule::InternalGenerateClassData_();

PROTOBUF_ATTRIBUTE_WEAK const ::google::protobuf::internal::ClassData* PROTOBUF_NONNULL
HttpRule::GetClassData() const {
  ::google::protobuf::internal::PrefetchToLocalCache(&HttpRule_class_data_);
  ::google::protobuf::internal::PrefetchToLocalCache(HttpRule_class_data_.tc_table);
  return HttpRule_class_data_.base();
}
PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1
const ::_pbi::TcParseTable<3, 10, 2, 82, 2>
HttpRule::_table_ = {
  {
    PROTOBUF_FIELD_OFFSET(HttpRule, _impl_._has_bits_),
    0, // no _extensions_
    12, 56,  // max_field_number, fast_idx_mask
    offsetof(decltype(_table_), field_lookup_table),
    4294963968,  // skipmap
    offsetof(decltype(_table_), field_entries),
    10,  // num_field_entries
    2,  // num_aux_entries
    offsetof(decltype(_table_), aux_entries),
    HttpRule_class_data_.base(),
    nullptr,  // post_loop_handler
    ::_pbi::TcParser::GenericFallback,  // fallback
    #ifdef PROTOBUF_PREFETCH_PARSE_TABLE
    ::_pbi::TcParser::GetTable<::google::api::HttpRule>(),  // to_prefetch
    #endif  // PROTOBUF_PREFETCH_PARSE_TABLE
  }, {{
    {::_pbi::TcParser::MiniParse, {}},
    // string selector = 1;
    {::_pbi::TcParser::FastUS1,
     {10, 0, 0, PROTOBUF_FIELD_OFFSET(HttpRule, _impl_.selector_)}},
    {::_pbi::TcParser::MiniParse, {}},
    // repeated .google.api.HttpRule additional_bindings = 11;
    {::_pbi::TcParser::FastMtR1,
     {90, 63, 1, PROTOBUF_FIELD_OFFSET(HttpRule, _impl_.additional_bindings_)}},
    // string response_body = 12;
    {::_pbi::TcParser::FastUS1,
     {98, 2, 0, PROTOBUF_FIELD_OFFSET(HttpRule, _impl_.response_body_)}},
    {::_pbi::TcParser::MiniParse, {}},
    {::_pbi::TcParser::MiniParse, {}},
    // string body = 7;
    {::_pbi::TcParser::FastUS1,
     {58, 1, 0, PROTOBUF_FIELD_OFFSET(HttpRule, _impl_.body_)}},
  }}, {{
    65535, 65535
  }}, {{
    // string selector = 1;
    {PROTOBUF_FIELD_OFFSET(HttpRule, _impl_.selector_), _Internal::kHasBitsOffset + 0, 0,
    (0 | ::_fl::kFcOptional | ::_fl::kUtf8String | ::_fl::kRepAString)},
    // string get = 2;
    {PROTOBUF_FIELD_OFFSET(HttpRule, _impl_.pattern_.get_), _Internal::kOneofCaseOffset + 0, 0,
    (0 | ::_fl::kFcOneof | ::_fl::kUtf8String | ::_fl::kRepAString)},
    // string put = 3;
    {PROTOBUF_FIELD_OFFSET(HttpRule, _impl_.pattern_.put_), _Internal::kOneofCaseOffset + 0, 0,
    (0 | ::_fl::kFcOneof | ::_fl::kUtf8String | ::_fl::kRepAString)},
    // string post = 4;
    {PROTOBUF_FIELD_OFFSET(HttpRule, _impl_.pattern_.post_), _Internal::kOneofCaseOffset + 0, 0,
    (0 | ::_fl::kFcOneof | ::_fl::kUtf8String | ::_fl::kRepAString)},
    // string delete = 5;
    {PROTOBUF_FIELD_OFFSET(HttpRule, _impl_.pattern_.delete__), _Internal::kOneofCaseOffset + 0, 0,
    (0 | ::_fl::kFcOneof | ::_fl::kUtf8String | ::_fl::kRepAString)},
    // string patch = 6;
    {PROTOBUF_FIELD_OFFSET(HttpRule, _impl_.pattern_.patch_), _Internal::kOneofCaseOffset + 0, 0,
    (0 | ::_fl::kFcOneof | ::_fl::kUtf8String | ::_fl::kRepAString)},
    // string body = 7;
    {PROTOBUF_FIELD_OFFSET(HttpRule, _impl_.body_), _Internal::kHasBitsOffset + 1, 0,
    (0 | ::_fl::kFcOptional | ::_fl::kUtf8String | ::_fl::kRepAString)},
    // .google.api.CustomHttpPattern custom = 8;
    {PROTOBUF_FIELD_OFFSET(HttpRule, _impl_.pattern_.custom_), _Internal::kOneofCaseOffset + 0, 0,
    (0 | ::_fl::kFcOneof | ::_fl::kMessage | ::_fl::kTvTable)},
    // repeated .google.api.HttpRule additional_bindings = 11;
    {PROTOBUF_FIELD_OFFSET(HttpRule, _impl_.additional_bindings_), -1, 1,
    (0 | ::_fl::kFcRepeated | ::_fl::kMessage | ::_fl::kTvTable)},
    // string response_body = 12;
    {PROTOBUF_FIELD_OFFSET(HttpRule, _impl_.response_body_), _Internal::kHasBitsOffset + 2, 0,
    (0 | ::_fl::kFcOptional | ::_fl::kUtf8String | ::_fl::kRepAString)},
  }},
  {{
      {::_pbi::TcParser::GetTable<::google::api::CustomHttpPattern>()},
      {::_pbi::TcParser::GetTable<::google::api::HttpRule>()},
  }},
  {{
    "\23\10\3\3\4\6\5\4\0\0\15\0\0\0\0\0"
    "google.api.HttpRule"
    "selector"
    "get"
    "put"
    "post"
    "delete"
    "patch"
    "body"
    "response_body"
  }},
};
PROTOBUF_NOINLINE void HttpRule::Clear() {
// @@protoc_insertion_point(message_clear_start:google.api.HttpRule)
  ::google::protobuf::internal::TSanWrite(&_impl_);
  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  _impl_.additional_bindings_.Clear();
  cached_has_bits = _impl_._has_bits_[0];
  if ((cached_has_bits & 0x00000007u) != 0) {
    if ((cached_has_bits & 0x00000001u) != 0) {
      _impl_.selector_.ClearNonDefaultToEmpty();
    }
    if ((cached_has_bits & 0x00000002u) != 0) {
      _impl_.body_.ClearNonDefaultToEmpty();
    }
    if ((cached_has_bits & 0x00000004u) != 0) {
      _impl_.response_body_.ClearNonDefaultToEmpty();
    }
  }
  clear_pattern();
  _impl_._has_bits_.Clear();
  _internal_metadata_.Clear<::google::protobuf::UnknownFieldSet>();
}

#if defined(PROTOBUF_CUSTOM_VTABLE)
::uint8_t* PROTOBUF_NONNULL HttpRule::_InternalSerialize(
    const ::google::protobuf::MessageLite& base, ::uint8_t* PROTOBUF_NONNULL target,
    ::google::protobuf::io::EpsCopyOutputStream* PROTOBUF_NONNULL stream) {
  const HttpRule& this_ = static_cast<const HttpRule&>(base);
#else   // PROTOBUF_CUSTOM_VTABLE
::uint8_t* PROTOBUF_NONNULL HttpRule::_InternalSerialize(
    ::uint8_t* PROTOBUF_NONNULL target,
    ::google::protobuf::io::EpsCopyOutputStream* PROTOBUF_NONNULL stream) const {
  const HttpRule& this_ = *this;
#endif  // PROTOBUF_CUSTOM_VTABLE
  // @@protoc_insertion_point(serialize_to_array_start:google.api.HttpRule)
  ::uint32_t cached_has_bits = 0;
  (void)cached_has_bits;

  // string selector = 1;
  if ((this_._impl_._has_bits_[0] & 0x00000001u) != 0) {
    if (!this_._internal_selector().empty()) {
      const ::std::string& _s = this_._internal_selector();
      ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
          _s.data(), static_cast<int>(_s.length()), ::google::protobuf::internal::WireFormatLite::SERIALIZE, "google.api.HttpRule.selector");
      target = stream->WriteStringMaybeAliased(1, _s, target);
    }
  }

  switch (this_.pattern_case()) {
    case kGet: {
      const ::std::string& _s = this_._internal_get();
      ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
          _s.data(), static_cast<int>(_s.length()), ::google::protobuf::internal::WireFormatLite::SERIALIZE, "google.api.HttpRule.get");
      target = stream->WriteStringMaybeAliased(2, _s, target);
      break;
    }
    case kPut: {
      const ::std::string& _s = this_._internal_put();
      ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
          _s.data(), static_cast<int>(_s.length()), ::google::protobuf::internal::WireFormatLite::SERIALIZE, "google.api.HttpRule.put");
      target = stream->WriteStringMaybeAliased(3, _s, target);
      break;
    }
    case kPost: {
      const ::std::string& _s = this_._internal_post();
      ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
          _s.data(), static_cast<int>(_s.length()), ::google::protobuf::internal::WireFormatLite::SERIALIZE, "google.api.HttpRule.post");
      target = stream->WriteStringMaybeAliased(4, _s, target);
      break;
    }
    case kDelete: {
      const ::std::string& _s = this_._internal_delete_();
      ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
          _s.data(), static_cast<int>(_s.length()), ::google::protobuf::internal::WireFormatLite::SERIALIZE, "google.api.HttpRule.delete");
      target = stream->WriteStringMaybeAliased(5, _s, target);
      break;
    }
    case kPatch: {
      const ::std::string& _s = this_._internal_patch();
      ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
          _s.data(), static_cast<int>(_s.length()), ::google::protobuf::internal::WireFormatLite::SERIALIZE, "google.api.HttpRule.patch");
      target = stream->WriteStringMaybeAliased(6, _s, target);
      break;
    }
    default:
      break;
  }
  // string body = 7;
  if ((this_._impl_._has_bits_[0] & 0x00000002u) != 0) {
    if (!this_._internal_body().empty()) {
      const ::std::string& _s = this_._internal_body();
      ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
          _s.data(), static_cast<int>(_s.length()), ::google::protobuf::internal::WireFormatLite::SERIALIZE, "google.api.HttpRule.body");
      target = stream->WriteStringMaybeAliased(7, _s, target);
    }
  }

  // .google.api.CustomHttpPattern custom = 8;
  if (this_.pattern_case() == kCustom) {
    target = ::google::protobuf::internal::WireFormatLite::InternalWriteMessage(
        8, *this_._impl_.pattern_.custom_, this_._impl_.pattern_.custom_->GetCachedSize(), target,
        stream);
  }

  // repeated .google.api.HttpRule additional_bindings = 11;
  for (unsigned i = 0, n = static_cast<unsigned>(
                           this_._internal_additional_bindings_size());
       i < n; i++) {
    const auto& repfield = this_._internal_additional_bindings().Get(i);
    target =
        ::google::protobuf::internal::WireFormatLite::InternalWriteMessage(
            11, repfield, repfield.GetCachedSize(),
            target, stream);
  }

  // string response_body = 12;
  if ((this_._impl_._has_bits_[0] & 0x00000004u) != 0) {
    if (!this_._internal_response_body().empty()) {
      const ::std::string& _s = this_._internal_response_body();
      ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
          _s.data(), static_cast<int>(_s.length()), ::google::protobuf::internal::WireFormatLite::SERIALIZE, "google.api.HttpRule.response_body");
      target = stream->WriteStringMaybeAliased(12, _s, target);
    }
  }

  if (ABSL_PREDICT_FALSE(this_._internal_metadata_.have_unknown_fields())) {
    target =
        ::_pbi::WireFormat::InternalSerializeUnknownFieldsToArray(
            this_._internal_metadata_.unknown_fields<::google::protobuf::UnknownFieldSet>(::google::protobuf::UnknownFieldSet::default_instance), target, stream);
  }
  // @@protoc_insertion_point(serialize_to_array_end:google.api.HttpRule)
  return target;
}

#if defined(PROTOBUF_CUSTOM_VTABLE)
::size_t HttpRule::ByteSizeLong(const MessageLite& base) {
  const HttpRule& this_ = static_cast<const HttpRule&>(base);
#else   // PROTOBUF_CUSTOM_VTABLE
::size_t HttpRule::ByteSizeLong() const {
  const HttpRule& this_ = *this;
#endif  // PROTOBUF_CUSTOM_VTABLE
  // @@protoc_insertion_point(message_byte_size_start:google.api.HttpRule)
  ::size_t total_size = 0;

  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void)cached_has_bits;

  ::_pbi::Prefetch5LinesFrom7Lines(&this_);
   {
    // repeated .google.api.HttpRule additional_bindings = 11;
    {
      total_size += 1UL * this_._internal_additional_bindings_size();
      for (const auto& msg : this_._internal_additional_bindings()) {
        total_size += ::google::protobuf::internal::WireFormatLite::MessageSize(msg);
      }
    }
  }
  cached_has_bits = this_._impl_._has_bits_[0];
  if ((cached_has_bits & 0x00000007u) != 0) {
    // string selector = 1;
    if ((cached_has_bits & 0x00000001u) != 0) {
      if (!this_._internal_selector().empty()) {
        total_size += 1 + ::google::protobuf::internal::WireFormatLite::StringSize(
                                        this_._internal_selector());
      }
    }
    // string body = 7;
    if ((cached_has_bits & 0x00000002u) != 0) {
      if (!this_._internal_body().empty()) {
        total_size += 1 + ::google::protobuf::internal::WireFormatLite::StringSize(
                                        this_._internal_body());
      }
    }
    // string response_body = 12;
    if ((cached_has_bits & 0x00000004u) != 0) {
      if (!this_._internal_response_body().empty()) {
        total_size += 1 + ::google::protobuf::internal::WireFormatLite::StringSize(
                                        this_._internal_response_body());
      }
    }
  }
  switch (this_.pattern_case()) {
    // string get = 2;
    case kGet: {
      total_size += 1 + ::google::protobuf::internal::WireFormatLite::StringSize(
                                      this_._internal_get());
      break;
    }
    // string put = 3;
    case kPut: {
      total_size += 1 + ::google::protobuf::internal::WireFormatLite::StringSize(
                                      this_._internal_put());
      break;
    }
    // string post = 4;
    case kPost: {
      total_size += 1 + ::google::protobuf::internal::WireFormatLite::StringSize(
                                      this_._internal_post());
      break;
    }
    // string delete = 5;
    case kDelete: {
      total_size += 1 + ::google::protobuf::internal::WireFormatLite::StringSize(
                                      this_._internal_delete_());
      break;
    }
    // string patch = 6;
    case kPatch: {
      total_size += 1 + ::google::protobuf::internal::WireFormatLite::StringSize(
                                      this_._internal_patch());
      break;
    }
    // .google.api.CustomHttpPattern custom = 8;
    case kCustom: {
      total_size += 1 +
                    ::google::protobuf::internal::WireFormatLite::MessageSize(*this_._impl_.pattern_.custom_);
      break;
    }
    case PATTERN_NOT_SET: {
      break;
    }
  }
  return this_.MaybeComputeUnknownFieldsSize(total_size,
                                             &this_._impl_._cached_size_);
}

void HttpRule::MergeImpl(::google::protobuf::MessageLite& to_msg, const ::google::protobuf::MessageLite& from_msg) {
  auto* const _this = static_cast<HttpRule*>(&to_msg);
  auto& from = static_cast<const HttpRule&>(from_msg);
  ::google::protobuf::Arena* arena = _this->GetArena();
  // @@protoc_insertion_point(class_specific_merge_from_start:google.api.HttpRule)
  ABSL_DCHECK_NE(&from, _this);
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  _this->_internal_mutable_additional_bindings()->MergeFrom(
      from._internal_additional_bindings());
  cached_has_bits = from._impl_._has_bits_[0];
  if ((cached_has_bits & 0x00000007u) != 0) {
    if ((cached_has_bits & 0x00000001u) != 0) {
      if (!from._internal_selector().empty()) {
        _this->_internal_set_selector(from._internal_selector());
      } else {
        if (_this->_impl_.selector_.IsDefault()) {
          _this->_internal_set_selector("");
        }
      }
    }
    if ((cached_has_bits & 0x00000002u) != 0) {
      if (!from._internal_body().empty()) {
        _this->_internal_set_body(from._internal_body());
      } else {
        if (_this->_impl_.body_.IsDefault()) {
          _this->_internal_set_body("");
        }
      }
    }
    if ((cached_has_bits & 0x00000004u) != 0) {
      if (!from._internal_response_body().empty()) {
        _this->_internal_set_response_body(from._internal_response_body());
      } else {
        if (_this->_impl_.response_body_.IsDefault()) {
          _this->_internal_set_response_body("");
        }
      }
    }
  }
  _this->_impl_._has_bits_[0] |= cached_has_bits;
  if (const uint32_t oneof_from_case = from._impl_._oneof_case_[0]) {
    const uint32_t oneof_to_case = _this->_impl_._oneof_case_[0];
    const bool oneof_needs_init = oneof_to_case != oneof_from_case;
    if (oneof_needs_init) {
      if (oneof_to_case != 0) {
        _this->clear_pattern();
      }
      _this->_impl_._oneof_case_[0] = oneof_from_case;
    }

    switch (oneof_from_case) {
      case kGet: {
        if (oneof_needs_init) {
          _this->_impl_.pattern_.get_.InitDefault();
        }
        _this->_impl_.pattern_.get_.Set(from._internal_get(), arena);
        break;
      }
      case kPut: {
        if (oneof_needs_init) {
          _this->_impl_.pattern_.put_.InitDefault();
        }
        _this->_impl_.pattern_.put_.Set(from._internal_put(), arena);
        break;
      }
      case kPost: {
        if (oneof_needs_init) {
          _this->_impl_.pattern_.post_.InitDefault();
        }
        _this->_impl_.pattern_.post_.Set(from._internal_post(), arena);
        break;
      }
      case kDelete: {
        if (oneof_needs_init) {
          _this->_impl_.pattern_.delete__.InitDefault();
        }
        _this->_impl_.pattern_.delete__.Set(from._internal_delete_(), arena);
        break;
      }
      case kPatch: {
        if (oneof_needs_init) {
          _this->_impl_.pattern_.patch_.InitDefault();
        }
        _this->_impl_.pattern_.patch_.Set(from._internal_patch(), arena);
        break;
      }
      case kCustom: {
        if (oneof_needs_init) {
          _this->_impl_.pattern_.custom_ = ::google::protobuf::Message::CopyConstruct(arena, *from._impl_.pattern_.custom_);
        } else {
          _this->_impl_.pattern_.custom_->MergeFrom(*from._impl_.pattern_.custom_);
        }
        break;
      }
      case PATTERN_NOT_SET:
        break;
    }
  }
  _this->_internal_metadata_.MergeFrom<::google::protobuf::UnknownFieldSet>(from._internal_metadata_);
}

void HttpRule::CopyFrom(const HttpRule& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:google.api.HttpRule)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}


void HttpRule::InternalSwap(HttpRule* PROTOBUF_RESTRICT PROTOBUF_NONNULL other) {
  using ::std::swap;
  auto* arena = GetArena();
  ABSL_DCHECK_EQ(arena, other->GetArena());
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
  _impl_.additional_bindings_.InternalSwap(&other->_impl_.additional_bindings_);
  ::_pbi::ArenaStringPtr::InternalSwap(&_impl_.selector_, &other->_impl_.selector_, arena);
  ::_pbi::ArenaStringPtr::InternalSwap(&_impl_.body_, &other->_impl_.body_, arena);
  ::_pbi::ArenaStringPtr::InternalSwap(&_impl_.response_body_, &other->_impl_.response_body_, arena);
  swap(_impl_.pattern_, other->_impl_.pattern_);
  swap(_impl_._oneof_case_[0], other->_impl_._oneof_case_[0]);
}

::google::protobuf::Metadata HttpRule::GetMetadata() const {
  return ::google::protobuf::Message::GetMetadataImpl(GetClassData()->full());
}
// ===================================================================

class CustomHttpPattern::_Internal {
 public:
  using HasBits =
      decltype(::std::declval<CustomHttpPattern>()._impl_._has_bits_);
  static constexpr ::int32_t kHasBitsOffset =
      8 * PROTOBUF_FIELD_OFFSET(CustomHttpPattern, _impl_._has_bits_);
};

CustomHttpPattern::CustomHttpPattern(::google::protobuf::Arena* PROTOBUF_NULLABLE arena)
#if defined(PROTOBUF_CUSTOM_VTABLE)
    : ::google::protobuf::Message(arena, CustomHttpPattern_class_data_.base()) {
#else   // PROTOBUF_CUSTOM_VTABLE
    : ::google::protobuf::Message(arena) {
#endif  // PROTOBUF_CUSTOM_VTABLE
  SharedCtor(arena);
  // @@protoc_insertion_point(arena_constructor:google.api.CustomHttpPattern)
}
PROTOBUF_NDEBUG_INLINE CustomHttpPattern::Impl_::Impl_(
    ::google::protobuf::internal::InternalVisibility visibility,
    ::google::protobuf::Arena* PROTOBUF_NULLABLE arena, const Impl_& from,
    const ::google::api::CustomHttpPattern& from_msg)
      : _has_bits_{from._has_bits_},
        _cached_size_{0},
        kind_(arena, from.kind_),
        path_(arena, from.path_) {}

CustomHttpPattern::CustomHttpPattern(
    ::google::protobuf::Arena* PROTOBUF_NULLABLE arena,
    const CustomHttpPattern& from)
#if defined(PROTOBUF_CUSTOM_VTABLE)
    : ::google::protobuf::Message(arena, CustomHttpPattern_class_data_.base()) {
#else   // PROTOBUF_CUSTOM_VTABLE
    : ::google::protobuf::Message(arena) {
#endif  // PROTOBUF_CUSTOM_VTABLE
  CustomHttpPattern* const _this = this;
  (void)_this;
  _internal_metadata_.MergeFrom<::google::protobuf::UnknownFieldSet>(
      from._internal_metadata_);
  new (&_impl_) Impl_(internal_visibility(), arena, from._impl_, from);

  // @@protoc_insertion_point(copy_constructor:google.api.CustomHttpPattern)
}
PROTOBUF_NDEBUG_INLINE CustomHttpPattern::Impl_::Impl_(
    ::google::protobuf::internal::InternalVisibility visibility,
    ::google::protobuf::Arena* PROTOBUF_NULLABLE arena)
      : _cached_size_{0},
        kind_(arena),
        path_(arena) {}

inline void CustomHttpPattern::SharedCtor(::_pb::Arena* PROTOBUF_NULLABLE arena) {
  new (&_impl_) Impl_(internal_visibility(), arena);
}
CustomHttpPattern::~CustomHttpPattern() {
  // @@protoc_insertion_point(destructor:google.api.CustomHttpPattern)
  SharedDtor(*this);
}
inline void CustomHttpPattern::SharedDtor(MessageLite& self) {
  CustomHttpPattern& this_ = static_cast<CustomHttpPattern&>(self);
  this_._internal_metadata_.Delete<::google::protobuf::UnknownFieldSet>();
  ABSL_DCHECK(this_.GetArena() == nullptr);
  this_._impl_.kind_.Destroy();
  this_._impl_.path_.Destroy();
  this_._impl_.~Impl_();
}

inline void* PROTOBUF_NONNULL CustomHttpPattern::PlacementNew_(
    const void* PROTOBUF_NONNULL, void* PROTOBUF_NONNULL mem,
    ::google::protobuf::Arena* PROTOBUF_NULLABLE arena) {
  return ::new (mem) CustomHttpPattern(arena);
}
constexpr auto CustomHttpPattern::InternalNewImpl_() {
  return ::google::protobuf::internal::MessageCreator::CopyInit(sizeof(CustomHttpPattern),
                                            alignof(CustomHttpPattern));
}
constexpr auto CustomHttpPattern::InternalGenerateClassData_() {
  return ::google::protobuf::internal::ClassDataFull{
      ::google::protobuf::internal::ClassData{
          &_CustomHttpPattern_default_instance_._instance,
          &_table_.header,
          nullptr,  // OnDemandRegisterArenaDtor
          nullptr,  // IsInitialized
          &CustomHttpPattern::MergeImpl,
          ::google::protobuf::Message::GetNewImpl<CustomHttpPattern>(),
#if defined(PROTOBUF_CUSTOM_VTABLE)
          &CustomHttpPattern::SharedDtor,
          ::google::protobuf::Message::GetClearImpl<CustomHttpPattern>(), &CustomHttpPattern::ByteSizeLong,
              &CustomHttpPattern::_InternalSerialize,
#endif  // PROTOBUF_CUSTOM_VTABLE
          PROTOBUF_FIELD_OFFSET(CustomHttpPattern, _impl_._cached_size_),
          false,
      },
      &CustomHttpPattern::kDescriptorMethods,
      &descriptor_table_google_2fapi_2fhttp_2eproto,
      nullptr,  // tracker
  };
}

PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 const
    ::google::protobuf::internal::ClassDataFull CustomHttpPattern_class_data_ =
        CustomHttpPattern::InternalGenerateClassData_();

PROTOBUF_ATTRIBUTE_WEAK const ::google::protobuf::internal::ClassData* PROTOBUF_NONNULL
CustomHttpPattern::GetClassData() const {
  ::google::protobuf::internal::PrefetchToLocalCache(&CustomHttpPattern_class_data_);
  ::google::protobuf::internal::PrefetchToLocalCache(CustomHttpPattern_class_data_.tc_table);
  return CustomHttpPattern_class_data_.base();
}
PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1
const ::_pbi::TcParseTable<1, 2, 0, 45, 2>
CustomHttpPattern::_table_ = {
  {
    PROTOBUF_FIELD_OFFSET(CustomHttpPattern, _impl_._has_bits_),
    0, // no _extensions_
    2, 8,  // max_field_number, fast_idx_mask
    offsetof(decltype(_table_), field_lookup_table),
    4294967292,  // skipmap
    offsetof(decltype(_table_), field_entries),
    2,  // num_field_entries
    0,  // num_aux_entries
    offsetof(decltype(_table_), field_names),  // no aux_entries
    CustomHttpPattern_class_data_.base(),
    nullptr,  // post_loop_handler
    ::_pbi::TcParser::GenericFallback,  // fallback
    #ifdef PROTOBUF_PREFETCH_PARSE_TABLE
    ::_pbi::TcParser::GetTable<::google::api::CustomHttpPattern>(),  // to_prefetch
    #endif  // PROTOBUF_PREFETCH_PARSE_TABLE
  }, {{
    // string path = 2;
    {::_pbi::TcParser::FastUS1,
     {18, 1, 0, PROTOBUF_FIELD_OFFSET(CustomHttpPattern, _impl_.path_)}},
    // string kind = 1;
    {::_pbi::TcParser::FastUS1,
     {10, 0, 0, PROTOBUF_FIELD_OFFSET(CustomHttpPattern, _impl_.kind_)}},
  }}, {{
    65535, 65535
  }}, {{
    // string kind = 1;
    {PROTOBUF_FIELD_OFFSET(CustomHttpPattern, _impl_.kind_), _Internal::kHasBitsOffset + 0, 0,
    (0 | ::_fl::kFcOptional | ::_fl::kUtf8String | ::_fl::kRepAString)},
    // string path = 2;
    {PROTOBUF_FIELD_OFFSET(CustomHttpPattern, _impl_.path_), _Internal::kHasBitsOffset + 1, 0,
    (0 | ::_fl::kFcOptional | ::_fl::kUtf8String | ::_fl::kRepAString)},
  }},
  // no aux_entries
  {{
    "\34\4\4\0\0\0\0\0"
    "google.api.CustomHttpPattern"
    "kind"
    "path"
  }},
};
PROTOBUF_NOINLINE void CustomHttpPattern::Clear() {
// @@protoc_insertion_point(message_clear_start:google.api.CustomHttpPattern)
  ::google::protobuf::internal::TSanWrite(&_impl_);
  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  cached_has_bits = _impl_._has_bits_[0];
  if ((cached_has_bits & 0x00000003u) != 0) {
    if ((cached_has_bits & 0x00000001u) != 0) {
      _impl_.kind_.ClearNonDefaultToEmpty();
    }
    if ((cached_has_bits & 0x00000002u) != 0) {
      _impl_.path_.ClearNonDefaultToEmpty();
    }
  }
  _impl_._has_bits_.Clear();
  _internal_metadata_.Clear<::google::protobuf::UnknownFieldSet>();
}

#if defined(PROTOBUF_CUSTOM_VTABLE)
::uint8_t* PROTOBUF_NONNULL CustomHttpPattern::_InternalSerialize(
    const ::google::protobuf::MessageLite& base, ::uint8_t* PROTOBUF_NONNULL target,
    ::google::protobuf::io::EpsCopyOutputStream* PROTOBUF_NONNULL stream) {
  const CustomHttpPattern& this_ = static_cast<const CustomHttpPattern&>(base);
#else   // PROTOBUF_CUSTOM_VTABLE
::uint8_t* PROTOBUF_NONNULL CustomHttpPattern::_InternalSerialize(
    ::uint8_t* PROTOBUF_NONNULL target,
    ::google::protobuf::io::EpsCopyOutputStream* PROTOBUF_NONNULL stream) const {
  const CustomHttpPattern& this_ = *this;
#endif  // PROTOBUF_CUSTOM_VTABLE
  // @@protoc_insertion_point(serialize_to_array_start:google.api.CustomHttpPattern)
  ::uint32_t cached_has_bits = 0;
  (void)cached_has_bits;

  // string kind = 1;
  if ((this_._impl_._has_bits_[0] & 0x00000001u) != 0) {
    if (!this_._internal_kind().empty()) {
      const ::std::string& _s = this_._internal_kind();
      ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
          _s.data(), static_cast<int>(_s.length()), ::google::protobuf::internal::WireFormatLite::SERIALIZE, "google.api.CustomHttpPattern.kind");
      target = stream->WriteStringMaybeAliased(1, _s, target);
    }
  }

  // string path = 2;
  if ((this_._impl_._has_bits_[0] & 0x00000002u) != 0) {
    if (!this_._internal_path().empty()) {
      const ::std::string& _s = this_._internal_path();
      ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
          _s.data(), static_cast<int>(_s.length()), ::google::protobuf::internal::WireFormatLite::SERIALIZE, "google.api.CustomHttpPattern.path");
      target = stream->WriteStringMaybeAliased(2, _s, target);
    }
  }

  if (ABSL_PREDICT_FALSE(this_._internal_metadata_.have_unknown_fields())) {
    target =
        ::_pbi::WireFormat::InternalSerializeUnknownFieldsToArray(
            this_._internal_metadata_.unknown_fields<::google::protobuf::UnknownFieldSet>(::google::protobuf::UnknownFieldSet::default_instance), target, stream);
  }
  // @@protoc_insertion_point(serialize_to_array_end:google.api.CustomHttpPattern)
  return target;
}

#if defined(PROTOBUF_CUSTOM_VTABLE)
::size_t CustomHttpPattern::ByteSizeLong(const MessageLite& base) {
  const CustomHttpPattern& this_ = static_cast<const CustomHttpPattern&>(base);
#else   // PROTOBUF_CUSTOM_VTABLE
::size_t CustomHttpPattern::ByteSizeLong() const {
  const CustomHttpPattern& this_ = *this;
#endif  // PROTOBUF_CUSTOM_VTABLE
  // @@protoc_insertion_point(message_byte_size_start:google.api.CustomHttpPattern)
  ::size_t total_size = 0;

  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void)cached_has_bits;

  ::_pbi::Prefetch5LinesFrom7Lines(&this_);
  cached_has_bits = this_._impl_._has_bits_[0];
  if ((cached_has_bits & 0x00000003u) != 0) {
    // string kind = 1;
    if ((cached_has_bits & 0x00000001u) != 0) {
      if (!this_._internal_kind().empty()) {
        total_size += 1 + ::google::protobuf::internal::WireFormatLite::StringSize(
                                        this_._internal_kind());
      }
    }
    // string path = 2;
    if ((cached_has_bits & 0x00000002u) != 0) {
      if (!this_._internal_path().empty()) {
        total_size += 1 + ::google::protobuf::internal::WireFormatLite::StringSize(
                                        this_._internal_path());
      }
    }
  }
  return this_.MaybeComputeUnknownFieldsSize(total_size,
                                             &this_._impl_._cached_size_);
}

void CustomHttpPattern::MergeImpl(::google::protobuf::MessageLite& to_msg, const ::google::protobuf::MessageLite& from_msg) {
  auto* const _this = static_cast<CustomHttpPattern*>(&to_msg);
  auto& from = static_cast<const CustomHttpPattern&>(from_msg);
  // @@protoc_insertion_point(class_specific_merge_from_start:google.api.CustomHttpPattern)
  ABSL_DCHECK_NE(&from, _this);
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  cached_has_bits = from._impl_._has_bits_[0];
  if ((cached_has_bits & 0x00000003u) != 0) {
    if ((cached_has_bits & 0x00000001u) != 0) {
      if (!from._internal_kind().empty()) {
        _this->_internal_set_kind(from._internal_kind());
      } else {
        if (_this->_impl_.kind_.IsDefault()) {
          _this->_internal_set_kind("");
        }
      }
    }
    if ((cached_has_bits & 0x00000002u) != 0) {
      if (!from._internal_path().empty()) {
        _this->_internal_set_path(from._internal_path());
      } else {
        if (_this->_impl_.path_.IsDefault()) {
          _this->_internal_set_path("");
        }
      }
    }
  }
  _this->_impl_._has_bits_[0] |= cached_has_bits;
  _this->_internal_metadata_.MergeFrom<::google::protobuf::UnknownFieldSet>(from._internal_metadata_);
}

void CustomHttpPattern::CopyFrom(const CustomHttpPattern& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:google.api.CustomHttpPattern)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}


void CustomHttpPattern::InternalSwap(CustomHttpPattern* PROTOBUF_RESTRICT PROTOBUF_NONNULL other) {
  using ::std::swap;
  auto* arena = GetArena();
  ABSL_DCHECK_EQ(arena, other->GetArena());
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
  ::_pbi::ArenaStringPtr::InternalSwap(&_impl_.kind_, &other->_impl_.kind_, arena);
  ::_pbi::ArenaStringPtr::InternalSwap(&_impl_.path_, &other->_impl_.path_, arena);
}

::google::protobuf::Metadata CustomHttpPattern::GetMetadata() const {
  return ::google::protobuf::Message::GetMetadataImpl(GetClassData()->full());
}
// @@protoc_insertion_point(namespace_scope)
}  // namespace api
}  // namespace google
namespace google {
namespace protobuf {
}  // namespace protobuf
}  // namespace google
// @@protoc_insertion_point(global_scope)
PROTOBUF_ATTRIBUTE_INIT_PRIORITY2 static ::std::false_type
    _static_init2_ [[maybe_unused]] =
        (::_pbi::AddDescriptors(&descriptor_table_google_2fapi_2fhttp_2eproto),
         ::std::false_type{});
#include "google/protobuf/port_undef.inc"
